﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="CadastroCategoriaListar.aspx.cs"
    Inherits="web.admin.CadastroCategoriaListar" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
     <title>Área Restrita</title>
</head>
<link href="../include/css/style.css" rel="stylesheet" type="text/css" />
<body>
    <form id="form1" runat="server">
    <br />
    <center>
        <table width="400">
            <tr>
                <td style="vertical-align: middle;">
                    <center>
                        <img src="../images/admin/icone_produto.png" />
                    </center>
                </td>
                <td style="vertical-align: middle; width: 80%; text-align: left">
                    <h2>
                        <b>Cadastro de Categorias</b></h2>
                </td>
            </tr>
        </table>
    </center>
    <a href="menu.aspx">.: Voltar :. </a>
    <br />
    <br />
    <center>
        <div style="overflow: auto; height: 469px">
            <table border="0" cellpadding="4" cellspacing="0" width="500">
                <tr>
                    <td>
                        <table border="0" cellpadding="4" cellspacing="0" align="left" width="100%">
                            <tr>
                                <td>
                                    <asp:HiddenField ID="hdnCodigo" runat="server" />
                                </td>
                            </tr>
                            <tr>
                                <table border="0" cellpadding="4" cellspacing="0" align="left" width="100%">
                                    <tr>
                                        <td>
                                            <td align="left">
                                                <asp:Label ID="Label3" runat="server" Text="Pesquisar:"></asp:Label>
                                            </td>
                                            <td align="left">
                                                <asp:TextBox class="input-text" ID="txtPesquisa" runat="server" Width="400"></asp:TextBox>
                                            </td>
                                            <td>
                                                <asp:DropDownList ID="cboTipoPesquisa" runat="server">
                                                    <asp:ListItem Text="Código" Value="0" />
                                                    <asp:ListItem Text="Descrição" Value="1" Selected="true" />
                                                </asp:DropDownList>
                                            </td>
                                            <td align="left">
                                                <asp:Button ID="btnPesquisar" runat="server" Text="Pesquisar" OnClick="btnPesquisar_Click" />
                                            </td>
                                            <td align="left">
                                                <asp:Button ID="btnNovo" runat="server" Text="Novo" OnClick="btnNovo_Click" />
                                            </td>
                                            <center>
                                                <asp:Label ID="lblMensagem" runat="server" ForeColor="Red" Text=""></asp:Label>
                                            </center>
                                        </td>
                                    </tr>
                                </table>
                            </tr>
                            <tr>
                                <td>
                                    <br />
                                    <asp:GridView ID="dtgResultado" runat="server" CellPadding="2" ForeColor="Black"
                                        GridLines="None" AutoGenerateColumns="False" OnRowDataBound="dtgResultado_RowDataBound"
                                        OnRowDeleting="dtgResultado_RowDeleting" BackColor="LightGoldenrodYellow" BorderColor="Tan"
                                        BorderWidth="1px" DataKeyNames="Codigo">
                                        <Columns>
                                            <asp:BoundField HeaderText="Codigo" DataField="Codigo">
                                                <HeaderStyle HorizontalAlign="Center" Width="5%" />
                                            </asp:BoundField>
                                            <asp:BoundField HeaderText="Titulo" DataField="DESCRICAO">
                                                <HeaderStyle HorizontalAlign="Center" Width="60%" />
                                            </asp:BoundField>
                                            <asp:TemplateField HeaderStyle-Width="10%" HeaderText="Ativo">
                                                <ItemTemplate>
                                                    <asp:Image ID="imgStatus" runat="server" />
                                                </ItemTemplate>
                                                <HeaderStyle Width="10%"></HeaderStyle>
                                            </asp:TemplateField>
                                            <asp:BoundField HeaderText="Ordem" DataField="ORDEM">
                                                <HeaderStyle HorizontalAlign="Center" Width="40%" />
                                            </asp:BoundField>
                                            <asp:TemplateField>
                                                <ItemTemplate>
                                                    <asp:ImageButton ID="Button1" ImageUrl="~/images/img_excluir.gif" runat="server"
                                                        Text="Excluir" CommandName="Delete" OnClientClick="return confirm('Tem certeza que quer excluir o produto?');" />
                                                </ItemTemplate>
                                            </asp:TemplateField>
                                        </Columns>
                                        <FooterStyle BackColor="Tan" />
                                        <PagerStyle BackColor="PaleGoldenrod" ForeColor="DarkSlateBlue" HorizontalAlign="Center" />
                                        <SelectedRowStyle BackColor="DarkSlateBlue" ForeColor="GhostWhite" />
                                        <HeaderStyle BackColor="Tan" Font-Bold="True" />
                                        <AlternatingRowStyle BackColor="PaleGoldenrod" />
                                    </asp:GridView>
                                </td>
                            </tr>
                        </table>
                    </td>
                </tr>
            </table>
    </center>
    </div>
    </form>
</body>
</html>
